-- GENERATED SPELL FOR [Scarlet Cavalier] --


function spell0_1836(pUnit, Event) --@Backhand,n/a--
pUnit:FullCastSpellOnTarget(6253,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_1836', 2291, 1)
end

function spell1_1836(pUnit, Event) --@Cleave,n/a--
pUnit:FullCastSpellOnTarget(15284,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_1836', 604, 1)
end

function spell2_1836(pUnit, Event) --@Mortal Strike,n/a--
pUnit:FullCastSpellOnTarget(16856,pUnit:GetMainTank ())
pUnit:RegisterEvent('Sorts_1836', 5340, 1)
end

function Sorts_1836(pUnit, Event)
local choix_sorts_1836 = math.random(0, 2)
if choix_sorts_1836 == 0 then
pUnit:RegisterEvent('spell0_1836', 1, 1)
end
if choix_sorts_1836 == 1 then
pUnit:RegisterEvent('spell1_1836', 1, 1)
end
if choix_sorts_1836 == 2 then
pUnit:RegisterEvent('spell2_1836', 1, 1)
end
end

function mob1836_Action(pUnit, Event)
pUnit:RegisterEvent('Sorts_1836', math.random(1500, 3000), 1)
end

function mob1836_Leave(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob1836_Kill(pUnit, Event)
--pUnit:RemoveEvents();--
end

function mob1836_Die(pUnit, Event)
pUnit:RemoveEvents();
end

RegisterUnitEvent(1836, 1, 'mob1836_Action')
RegisterUnitEvent(1836, 2, 'mob1836_Leave')
RegisterUnitEvent(1836, 3, 'mob1836_Kill')
RegisterUnitEvent(1836, 4, 'mob1836_Die')
